<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>posix_setrlimit constants</title>
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-base.css" />
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-medium.css" />

 </head>
 <body class="docs"><div class="navbar navbar-fixed-top">
  <div class="navbar-inner clearfix">
    <ul class="nav" style="width: 100%">
      <li style="float: left;"><a href="posix.constants.mknod.html">« posix_mknod constants</a></li>
      <li style="float: right;"><a href="ref.posix.html">POSIX 函数 »</a></li>
    </ul>
  </div>
</div>
<div id="breadcrumbs" class="clearfix">
  <ul class="breadcrumbs-container">
    <li><a href="index.html">PHP Manual</a></li>
    <li><a href="posix.constants.html">预定义常量</a></li>
    <li>posix_setrlimit constants</li>
  </ul>
</div>
<div id="layout">
  <div id="layout-content"><div id="posix.constants.setrlimit" class="section">
  <h2 class="title"><span class="function"><a href="function.posix-setrlimit.html" class="function">posix_setrlimit()</a></span> constants</h2>
  <blockquote class="note"><p><strong class="note">注意</strong>: 
   <p class="para">
    Please note that some of them may not be available on your system.
   </p>
  </p></blockquote>
  <blockquote class="note"><p><strong class="note">注意</strong>: 
   <p class="para">
    You may wish to read the below notes in conjunction with the manpage for
    <span class="function"><strong>setrlimit()</strong></span> on your specific operating system, as there
    is variance in how these limits are interpreted, even across operating
    systems that claim to implement POSIX in full.
   </p>
  </p></blockquote>
  <dl>
   
    <dt id="constant.posix-rlimit-as">
     <strong><code>POSIX_RLIMIT_AS</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of the process&#039;s address space in bytes. See also PHP&#039;s
      <a href="ini.core.html#ini.memory-limit" class="link">memory_limit</a> configuration
      directive.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-core">
     <strong><code>POSIX_RLIMIT_CORE</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of a core file. If the limit is set to 0, no core file
      will be generated.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-cpu">
     <strong><code>POSIX_RLIMIT_CPU</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum amount of CPU time that the process can use, in seconds.
      When the soft limit is hit, a <code class="literal">SIGXCPU</code> signal will be
      sent, which can be caught with <span class="function"><a href="function.pcntl-signal.html" class="function">pcntl_signal()</a></span>.
      Depending on the operating system, additional <code class="literal">SIGXCPU</code>
      signals may be sent each second until the hard limit is hit, at which
      point an uncatchable <code class="literal">SIGKILL</code> signal is sent.
     </span>
     <span class="simpara">
      See also <span class="function"><a href="function.set-time-limit.html" class="function">set_time_limit()</a></span>.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-data">
     <strong><code>POSIX_RLIMIT_DATA</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of the process&#039;s data segment, in bytes. It is
      extremely unlikely that this will have any effect on the execution of
      PHP unless an extension is in use that calls <span class="function"><strong>brk()</strong></span> or
      <span class="function"><strong>sbrk()</strong></span>.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-fsize">
     <strong><code>POSIX_RLIMIT_FSIZE</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of files that the process can create, in bytes.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-locks">
     <strong><code>POSIX_RLIMIT_LOCKS</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of locks that the process can create. This is only
      supported on extremely old Linux kernels.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-memlock">
     <strong><code>POSIX_RLIMIT_MEMLOCK</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of bytes that can be locked into memory.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-msgqueue">
     <strong><code>POSIX_RLIMIT_MSGQUEUE</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of bytes that can be allocated for POSIX message
      queues. PHP does not ship with support for POSIX message queues, so this
      limit will not have any effect unless you are using an extension that
      implements that support.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-nice">
     <strong><code>POSIX_RLIMIT_NICE</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum value to which the process can be
      <a href="function.pcntl-setpriority.html" class="link">reniced</a> to. The value
      that will be used will be <code class="literal">20 - limit</code>, as resource
      limit values cannot be negative.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-nofile">
     <strong><code>POSIX_RLIMIT_NOFILE</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      A value one greater than the maximum file descriptor number that can be
      opened by this process.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-nproc">
     <strong><code>POSIX_RLIMIT_NPROC</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of processes (and/or threads, on some operating
      systems) that can be created for the real user ID of the process.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-rss">
     <strong><code>POSIX_RLIMIT_RSS</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of the process&#039;s resident set, in pages.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-rtprio">
     <strong><code>POSIX_RLIMIT_RTPRIO</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum real time priority that can be set via the
      <span class="function"><strong>sched_setscheduler()</strong></span> and
      <span class="function"><strong>sched_setparam()</strong></span> system calls.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-rttime">
     <strong><code>POSIX_RLIMIT_RTTIME</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum amount of CPU time, in microseconds, that the process can
      consume without making a blocking system call if it is using real time
      scheduling.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-sigpending">
     <strong><code>POSIX_RLIMIT_SIGPENDING</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of signals that can be queued for the real user ID of
      the process.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-stack">
     <strong><code>POSIX_RLIMIT_STACK</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum size of the process stack, in bytes.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-infinity">
     <strong><code>POSIX_RLIMIT_INFINITY</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      Used to indicate an infinite value for a resource limit.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-kqueues">
     <strong><code>POSIX_RLIMIT_KQUEUES</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of kqueues this user id is allowed to create (FreeBSD).
      Available as of PHP 8.1.0.
     </span>
    </dd>

   
   
    <dt id="constant.posix-rlimit-npts">
     <strong><code>POSIX_RLIMIT_NPTS</code></strong>
      (<span class="type">int</span>)
    </dt>

    <dd>

     <span class="simpara">
      The maximum number of pseudo-terminals this user id is allowed to create (FreeBSD).
      Available as of PHP 8.1.0.
     </span>
    </dd>

   
  </dl>

 </div></div></div></body></html>